<form action="<?php echo base_url() ?>sinhvien/xuly_them_don" method="post" enctype="multipart/form-data">

    <input type="hidden" name="Ma_BieuMau" value="<?php echo $Ma_BieuMau; ?>" />

    <table  >
        <caption>
            <h3>Sinh viên điền thông tin</h3>
        </caption>

        <?php
        foreach ($dsinput as $key => $value) {
            if ($value['F'] == 1) {
                echo '<tr><td>';
                echo $value['Nhan'];
                echo '</td><td>';
                switch ($value['type']) {
                    case 1:

                        echo '<input type="text" name="datainput[' . $value['ViTriO'] . ']" required="">';

                        break;
                    case 2:
                        echo '<textarea name="datainput[' . $value['ViTriO'] . ']" style="width: 400px;height: 170px" required=""></textarea>';
                        break;
                    default:
                        break;
                }
                echo '</td></tr>';
            } else {
                echo form_hidden('datainput[' . $value['ViTriO'] . ']', $user[$value['Nhan']]);
            }
        }
        ?>



    </table>

    <button type="submit" name="bt" value="0">Hủy</button>
    <?php
    if ($LoaiDon == 0) {
        echo '<button type="submit" name="bt" value="2">Lưu đơn</button>';
    }

    if ($LoaiDon == 1) {
        echo '<button type="submit" name="bt" value="1">Gửi</button>';
    }
    ?>




</form>

